function Bullet(startX,startY,startDegrees,startDamage){
    var instanse=this;
    
    
    instanse.x;
    instanse.y;
    instanse.degrees;
    var speed;
    instanse.damage;
    /* constructor */
    (function(){
        instanse.x = startX;
        instanse.y = startY;
        instanse.degrees = startDegrees;
        instanse.damage = startDamage;
        speed = 4;
    })();
    
    /* public  */
    instanse.Replace = function(){
        
        /* drow korpus */
                if (instanse.x+speed*(Math.cos(instanse.degrees.degree()))>0 && instanse.x+speed*(Math.cos(instanse.degrees.degree()))<600)
                {
                    instanse.x+=speed * (Math.cos(instanse.degrees.degree()));
                }
                if (instanse.y+speed*(Math.sin(instanse.degrees.degree()))>0 && instanse.y+speed*(Math.sin(instanse.degrees.degree()))<600)
                {    
                    instanse.y+=speed * (Math.sin(instanse.degrees.degree()));
                }               
    };   
     
     /* rad => degree */
     Number.prototype.degree = function () {
        return this * Math.PI / 180;
     };    
    
};